package inherit_0909;

/**
 * 继承：可以多层继承不可以多重继承
 */
public class Test {
    public static void main(String[] args) {
        Dog dog=new Dog();
        Cat cat=new Cat();
        dog.name="小狗";
        dog.eat("骨头");
        dog.sleep();
        dog.bark();
        cat.name="小猫";
        cat.eat("小鱼");
        cat.sleep();
        cat.bark();

    }
}
